package com.lzt.bootdemo.controller;

import com.lzt.bootdemo.pojo.Student;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;
@RestController
public class StudentController {

    @GetMapping("/student")
    public List<Student> query()
    {
        Student s = new Student(1,"刘怀",15,new Date());
        Student s1 = new Student(1,"何",16,new Date());
        List<Student> list = new ArrayList<>();
        list.add(s);
        list.add(s1);

        return list;
    }
}
